package com.github.androiddevelopmentframework.record.presenter;

import com.github.androiddevelopmentframework.record.bean.OrderRecordBean;
import com.github.androiddevelopmentframework.record.recordInterface.RecordInterface;
import com.github.freewu.commons.http.HttpDataProcess;
import com.github.freewu.mvp.bean.ServerListBean;
import com.github.freewu.mvp.presenter.HttpPresenter;

import java.util.List;

/**
 * Created by free on 16-8-2.
 */
public class RecordPresenter extends HttpPresenter<RecordInterface.ViewInterface,RecordInterface.ApiServer> {


    public RecordPresenter(RecordInterface.ViewInterface mView) {
        super(mView);
    }

    @Override
    public Class<RecordInterface.ApiServer> getApiServerClass() {
        return RecordInterface.ApiServer.class;
    }

    private void test(){
        getProcess().doListBean(getApiServer().getRecord("", 1, 10),
                new HttpDataProcess.Action<List<OrderRecordBean>, ServerListBean>() {
                    @Override
                    public void onResult(List<OrderRecordBean> result, ServerListBean serverListBean) {

                    }
                });
    }
}
